import { useForm } from "@ant-design-vue/use";
const rulesAddTimeFrom = {
  date: [{ required: true, message: '请选择计划日期'}],
  time: [{ required: true, message: '请选择耗时'}],
  content: [{ required: true, message: '请输入备注'}]
}
// const { validateInfos, validate, resetFields } = useForm(state.form, rulesAddTimeFrom);
// export {
//   validateInfos,
//   validate,
//   resetFields
// }
// interface CheckStateType {
//   date: string
//   time: number
//   content: string
// }
export function checkFrom (checkState: Object) {
  console.log('state: ', checkState)
  const { validateInfos, validate, resetFields } = useForm(checkState, rulesAddTimeFrom);
  return {
    validateInfos,
    validate,
    resetFields
  }
}